<%@ page language="java" contentType="text/html; charset=UTF-8"
         pageEncoding="UTF-8"%>
<%@ page isELIgnored="false" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt"  prefix="fmt"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title>维护人列表</title>
</head>
<body>
<form action="${pageContext.request.contextPath }/queryItem.action" method="post">
    查询条件：
    <table width="100%" border=1>
        <tr>
            <td>商品id<input type="text" name="item.id"/> </td>
            <td>商品名称<input type="text" name="item.name"/> </td>
            <td><input type="submit" value="查询"/></td>
        </tr>
    </table>
    商品列表：
    <table width="100%" border=1>
        <tr>
            <td>选中</td>
            <td>名字</td>
            <td>生日</td>
            <td>性别</td>
            <td></td>
            <td>地址</td>
        </tr>
        <c:forEach items="${users }" var="user">
            <tr>
                <td><input type="checkbox" name="ids" value="${user.id}"></td>
                <td>${user.username }</td>
                <td><fmt:formatDate value="${user.birthday}" pattern="yyyy-MM-dd"/></td>
                <td>${user.address }</td>
                <td>
                    <c:if test="${user.sex==1}">
                        男
                    </c:if>
                    <c:if test="${user.sex==2}">
                        女
                    </c:if>
                </td>
                <td><a href="${pageContext.request.contextPath }/itemEdit.action?itemId=${user.id}">修改</a></td>

            </tr>
        </c:forEach>

    </table>
</form>
</body>

</html>